package camid.test.util;


public class AsyncUtil {

	public static void runAsync(Object[] resultSet, AsyncCall caller)
	{
		int size = resultSet.length;
		for(int i = 0; i < size; i++)
		{
			Thread t = new Thread( new AsyncCallRunnable(i, resultSet[i], caller));
			t.start();
		}
	}

	public static void runSync(Object[] resultSet, AsyncCall caller)
	{
		int size = resultSet.length;
		for(int i = 0; i < size; i++)
		{
			new AsyncCallRunnable(i, resultSet[i], caller).run();
		}
	}

}
